import Vue from 'vue'
import Router from 'vue-router'
// import HelloWorld from '@/components/HelloWorld'
import index from "../components/index.vue"
import my from "../components/my.vue"
import nearby from "../components/nearby.vue"
import more from "../components/more.vue"
import register from "../components/register.vue"
import login from "../components/login.vue"
import detail from "../components/detail.vue"
import car from "../components/car.vue"

Vue.use(Router)

export default new Router({
  routes: [
    {
        path:"*",
        redirect:"/index"
    },
     {
        path:"/index",
        name:"index",
        component:index
    },
    {
        path:"/",
        name:"index",
        component:index
    },
    {
        path:"/more",
        name:"more",
        component:more
    },
    {
        path:"/my",
        name:"my",
        component:my
    },
    {
        path:"/nearby",
        name:"nearby",
        component:nearby
    },{
        path:"/register",
        name:"register",
        component:register
    },{
        path:"/login",
        name:"login",
        component:login
    }
    ,{
        path:"/detail",
        name:"detail",
        component:detail
    },{
        path:"/car",
        name:"car",
        component:car
    }
    ]
})
